TypeScript 55.4%
Python 43.2%
SQL 1.2%
1import { permanentRedirect } from "next/navigation";23export const dynamic = "force-dynamic";45/** `/company/:id` is the legacy entity URL — permanently redirected to `/entity/:id` (tab preserved). */6export default async function CompanyPage({ params, searchParams }: { params: Promise<{ id: string }>; searchParams: Promise<{ tab?: string; range?: string; cursor?: string }> }) {7 const { id } = await params;8 const sp = await searchParams;9 const q = new URLSearchParams();10 if (sp.tab) q.set("tab", sp.tab);11 if (sp.range) q.set("range", sp.range);12 if (sp.cursor) q.set("cursor", sp.cursor);13 const s = q.toString();14 permanentRedirect(`/entity/${encodeURIComponent(id)}${s ? `?${s}` : ""}`);15}16